home *** CD-ROM | disk | FTP | other *** search
/ AM/FM: Amiga Musicians' Freeware Magazine 3 / AM-FM 3.adf / text / TIME.TXT.pp / TIME.TXT
Text File  |  1991-11-05  |  33KB  |  954 lines

  1.  
  2.  
  3. Detailed Specification
  4.  
  5. (Supplement to MIDI 1.0)
  6.  
  7. 12 February 1987
  8.  
  9. Justification For  MIDI Time Code and Cueing
  10.  
  11.  
  12.  
  13.      The merit of implementing the MIDI Time Code proposal within the current
  14. MIDI specification is as follows:
  15.  
  16.      SMPTE has become the de facto  timing reference standard in the
  17. professional audio world and in almost the entire video world.  SMPTE is also
  18. seeing more and more use in the semi-professional audio area.  We hope to
  19. combine this universal timing reference, SMPTE, with the de facto  standard
  20. for controlling musical equipment, MIDI.
  21.  
  22.      Encoding SMPTE over MIDI allows a person to work with one timing
  23. reference throughout the entire system.  For example, studio engineers are
  24. more familiar with the idea of telling a multitrack recorder to punch in and
  25. out of record mode at specific SMPTE times, as opposed to a specific beat in a
  26. specific bar.  To force a musician or studio engineer to convert back and
  27. forth between a SMPTE time and a specific bar number is tedious and should not
  28. be necessary (one would have to take into account tempo and tempo changes,
  29. etc.).
  30.  
  31.      Also, some operations are referenced only as SMPTE times, as opposed to
  32. beats in a bar.  For example, creating audio and sound effects for video
  33. requires that certain sounds and sequences be played at specific SMPTE times.
  34. There is no other easy way to do this with Song Position Pointers, etc., and
  35. even if there was, it would be an unnatural way for a video or recording
  36. engineer to work.
  37.  
  38.      MIDI Time Code is an absolute timing reference, whereas MIDI Clock and
  39. Song Position Pointer are relative timing references.  In virtually all audio
  40. for film/video work, SMPTE is already being used as the main time base, and
  41. any musical passages which need to be recorded are usually done by getting a
  42. MIDI-based sequencer to start at a pre-determined SMPTE time code.  In most
  43. cases, though, it is SMPTE which is the Master timing reference being used.
  44. In order for MIDI-based devices to operate on an absolute time code which is
  45. independent of tempo, MIDI Time Code must be used. Existing devices merely
  46. translate SMPTE into MIDI Clocks and Song Position Pointers based upon a given
  47. tempo.  This is not absolute time, but relative time, and all of the SMPTE cue
  48. points will change if the tempo changes.  The majority of sound effects work
  49. for film and video does not involve musical passages with tempos, rather it
  50. involves individual sound effect "events" which must occur at specific,
  51. absolute times, not relative to any "tempo".
  52.  
  53.  
  54.  
  55. MIDI Time Code System Components
  56.  
  57.  
  58.  
  59. SMPTE to MTC Converter
  60.  
  61.      This box would either convert longitudinal (audio-type) or vertical
  62. (video-type) SMPTE time code from a master timing device into MTC. The
  63. function could be integrated into video tape recorders (VTRs) or
  64. syncronization units that control audio tape recorders (ATRs). Alternately, a
  65. stand-alone box would do the conversion, or simply generate MTC directly.
  66. Note that conversion from MTC to SMPTE time code is not envisioned, as it is
  67. of little practical value.
  68.  
  69.  
  70.  
  71. Cue List Manager
  72.  
  73.      This would be a device or computer program that would maintain a cue list
  74. of desired events, and send the list to the slaves. For performance, the
  75. manager might pass the Time Code from the SMPTE-MTC converter through to the
  76. slaves, or, in a stand-alone system it might generate Time Code itself. This
  77. "central controller" would presumably also contain all library functions for
  78. downloading sound programs, samples, sequences, patterns, and so on, to the
  79. slaves. A Cue List Manager would pre-load intelligent MTC peripherals (see
  80. below) with this data.
  81.  
  82.  
  83.  
  84. MTC Sequencer
  85.  
  86.      To control existing equipment or any device which does not recognize MTC
  87. in an MTC system, this device would be needed. It would receive the cue list
  88. from the manager, and convert the cues into normal MIDI commands.   At the
  89. specified SMPTE times, the sequencer would then send the MIDI commands to the
  90. specific devices. For example, for existing MIDI equipment it might provide
  91. MIDI messages such as Note On, Note Off, Song Select, Start, Stop, Program
  92. Changes, etc. Non-MIDI equipment (such as CD players, mixing consoles,
  93. lighting, sound effects cartridge units and ATRs) may also be controlled if
  94. such a device had relay controls.
  95.  
  96.  
  97.  
  98. Intelligent MTC Peripheral
  99.  
  100.      In this category belong devices capable of receiving an MTC Cue List from
  101. the manager, and triggering themselves appropriately when the correct Time
  102. Code (SMPTE or MIDI) has been received.  Above this minimum, the device might
  103. be able to change its programming in response to the Cue List, or prepare
  104. itself for ensuing events.
  105.  
  106.      For example, an intelligent MTC-equipped analog multitrack tape machine
  107. might read in a list of punch in/punch out cues from the Cue List Manager, and
  108. then alter then to internally compensate for its bias current rise and fall
  109. times. A sampling-based sound effects device might preload samples from its
  110. own disk drive into a RAM buffer, in anticipation of needing them for cues
  111. later on in the cue list.
  112.  
  113.      It should be mentioned that while these functions are separately
  114. described, actual devices may incorporate a mixture of these functions, suited
  115. to specific applications in their market.
  116.  
  117.  
  118. A MIDI Time Code System
  119.  
  120.      The MIDI Time Code format contains two parts: Time Code and Set Up. Time
  121. Code is relatively straightforward: hours, minutes, seconds and frame numbers
  122. (approximately 1/30 of a second) are encoded and distributed throughout the
  123. MIDI system so that all the units know exactly what time it is.
  124.  
  125.      Set Up, however, is where MTC gains its power. It is a format for
  126. informing MIDI devices of events to be performed at specific times.
  127. Ultimately, this aspect of MTC will lead to the creation of an entirely new
  128. class of production equipment. Before getting into the nuts and bolts of the
  129. spec itself, let's talk about some of the uses and features of forthcoming
  130. devices that have been envisioned.
  131.  
  132.      Set Up begins with the concept of a cue list. In video editing, for
  133. example, it is customary to transfer the video master source tapes, which may
  134. be on expensive, two-inch recorders, to less-expensive recorders. The editing
  135. team then works over this copy, making a list of all the segments that they
  136. want to piece together as they are defined by their SMPTE times.
  137.  
  138.      For example, the first scene starts at time A and ends at time B, the
  139. next scene starts at time C and ends at time D. A third scene may even lie
  140. between the first two. When done, they feed this cue list time information
  141. into the editing system of the master recorder(s) or just give the cue list to
  142. an editor who does the work manually. The editing system or editor then
  143. locates the desired segments and assembles them in the proper sequence.
  144.  
  145.  
  146.  
  147.      Now suppose that instead of one or two video recorders, we have twenty
  148. devices that will play a part in our audio/video or film production:  special
  149. effects generators for fades and superimpositions, additional decks with
  150. background scenery, live cameras, MIDI sequencers, drum machines,
  151. synthesizers, samplers, DDLs, soundtrack decks, CDs, effects devices, and so
  152. on. As it stands now, each of these devices must be handled more or less
  153. separately, with painstaking and time-consuming assembly editing or multitrack
  154. overdubs. And when a change in the program occurs (which always happens),
  155. anywhere from just a few items to the whole system may need to be reprogrammed
  156. by hand.
  157.  
  158.  
  159.  
  160.      This is where MIDI Time Code comes in. It can potentially control all of
  161. these individual production elements so that they function together from a
  162. single cue list. The master controller which would handle this function is
  163. described as a Cue List Manager. On such a console, you would list what you
  164. want each device to do, and when to do it. The manager would then send the cue
  165. list to the various machines via the MTC Set Up protocol. Each unit would then
  166. react as programmed when the designated MIDI Time Code (or conventional SMPTE
  167. Time Code) appears. Changes? No problem. Simply edit the cue list using simple
  168. word-processing functions, then run the tape again.
  169.  
  170.  
  171.      MTC thus integrates into a manageable system all of the diverse tools at
  172. our disposal. It would drastically reduce the time, money and frustration
  173. needed to produce a film or video.
  174.  
  175.  
  176.      Having covered the basic aspects of a MIDI Time Code system, as well as
  177. examples of how an overall system might function, we will now take a look at
  178. the actual MIDI specification itself.
  179.  
  180.  
  181. MIDI Time Code
  182.  
  183.  
  184.  
  185.      For device synchronization, MIDI Time Code uses two basic types of
  186. messages, described as Quarter Frame and Full. There is also a third, optional
  187. message for encoding SMPTE user bits.
  188.  
  189.  
  190. Quarter Frame Messages
  191.  
  192.  
  193.  
  194.      Quarter Frame messages are used only while the system is running. They
  195. are rather like the PPQN or MIDI clocks to which we are accustomed. But there
  196. are several important ways in which Quarter Frame messages differ from the
  197. other systems.
  198.  
  199.  
  200.      As their name implies, they have fine resolution. If we assume 30 frames
  201. per second, there will be 120 Quarter Frame messages per second. This
  202. corresponds to a maximum latency  of 8.3 milliseconds (at 30 frames per
  203. second), with accuracy greater than this possible within the specific device
  204. (which may interpolate inbetween quarter frames to "bit" resolution).  Quarter
  205. Frame messages serve a dual purpose: besides providing the basic timing pulse
  206. for the system, each message contains a unique nibble (four bits) defining a
  207. digit of a specific field of the current SMPTE time.
  208.  
  209.  
  210.  
  211.      Quarter frames messages should be thought of as groups of eight messages.
  212. One of these groups encodes the SMPTE time in hours, minutes, seconds, and
  213. frames. Since it takes eight quarter frames for a complete time code message,
  214. the complete SMPTE time is updated every two frames.  Each quarter frame
  215. message contains two bytes. The first byte is F1,  the Quarter Frame System
  216. Common byte. The second byte contains a nibble that represents the message
  217. number (0 through 7), and a nibble for one of the digits of a time field
  218. (hours, minutes, seconds or frames).
  219.  
  220.  
  221.  
  222.  
  223.  
  224. Quarter Frame Messages (2 bytes):
  225.  
  226.  
  227.  
  228.      F1  <message>
  229.  
  230.  
  231.  
  232.           F1 = Currently unused and undefined System Common status byte
  233.  
  234.           <message> = 0nnn dddd
  235.  
  236.  
  237.  
  238.                dddd = 4 bits of binary data for this Message Type
  239.  
  240.                nnn =  Message Type:
  241.  
  242.                     0 = Frame count LS nibble
  243.  
  244.                     1 = Frame count MS nibble
  245.  
  246.                     2 = Seconds count LS nibble
  247.  
  248.                     3 = Seconds count MS nibble
  249.  
  250.                     4 = Minutes count LS nibble
  251.  
  252.                     5 = Minutes count MS nibble
  253.  
  254.                     6 = Hours count LS nibble
  255.  
  256.                     7 = Hours count MS nibble and SMPTE Type
  257.  
  258.  
  259.  
  260.      After both the MS nibble and the LS nibble of the above counts are
  261. assembled, their bit fields are assigned as follows:
  262.  
  263.  
  264.  
  265. FRAME COUNT:  xxx yyyyy
  266.  
  267.  
  268.  
  269.                xxx = undefined and reserved for future use.  Transmitter
  270.  
  271.                     must set these bits to 0 and receiver should ignore!
  272.  
  273.                yyyyy = Frame number (0-29)
  274.  
  275.  
  276.  
  277. SECONDS COUNT:  xx yyyyyy
  278.  
  279.  
  280.  
  281.                xx = undefined and reserved for future use.  Transmitter
  282.  
  283.                      must set these bits to 0 and receiver should ignore!
  284.  
  285.                yyyyyy = Seconds Count  (0-59)
  286.  
  287.  
  288.  
  289. MINUTES COUNT:  xx yyyyyy
  290.  
  291.  
  292.  
  293.                xx = undefined and reserved for future use.  Transmitter
  294.  
  295.                      must set these bits to 0 and receiver should ignore!
  296.  
  297.                yyyyyy = Minutes Count  (0-59)
  298.  
  299.  
  300.  
  301. HOURS COUNT:  x yy zzzzz
  302.  
  303.  
  304.  
  305.                x = undefined and reserved for future use.  Transmitter
  306.  
  307.                      must set this bit to 0 and receiver should ignore!
  308.  
  309.  
  310.  
  311.                yy = Time Code Type:
  312.  
  313.                     0 = 24 Frames/Second
  314.  
  315.                     1 = 25 Frames/Second
  316.  
  317.                     2 = 30 Frames/Second (Drop-Frame)
  318.  
  319.                     3 = 30 Frames/Second (Non-Drop)
  320.  
  321.  
  322.  
  323.                zzzzz = Hours Count  (0-23)
  324.  
  325.  
  326. Quarter Frame Message Implementation
  327.  
  328.  
  329.  
  330.      When time code is running in the forward direction, the device producing
  331. the MIDI Time Code will send Quarter Frame messages at quarter frame intervals
  332. in the following order:
  333.  
  334.  
  335.  
  336.                     F1 0X
  337.  
  338.                     F1 1X
  339.  
  340.                     F1 2X
  341.  
  342.                     F1 3X
  343.  
  344.                     F1 4X
  345.  
  346.                     F1 5X
  347.  
  348.                     F1 6X
  349.  
  350.                     F1 7X
  351.  
  352.  
  353.  
  354. after which the sequence repeats itself, at a rate of one complete 8-message
  355. sequence every 2 frames (8 quarter frames).  When time code is running in
  356. reverse, the quarter frame messages are sent in reverse order, starting with
  357. F1 7X and ending with F1 0X.  Again, at least 8 quarter frame messages must be
  358. sent.  The arrival of the F1 0X and F1 4X messages always denote frame
  359. boundaries.
  360.  
  361.  
  362.  
  363.      Since 8 quarter frame messages are required to definitely establish the
  364. actual SMPTE time, timing lock cannot be achieved until the reader has read a
  365. full sequence of 8 messages, from first message to last.  This will take from
  366. 2 to 4 frames to do, depending on when the reader comes on line.
  367.  
  368.  
  369.      During fast forward, rewind or shuttle modes, the time code generator
  370. should stop sending quarter frame messages, and just send a Full Message once
  371. the final destination has been reached.  The generator can then pause for any
  372. devices to shuttle to that point, and resume by sending quarter frame messages
  373. when play mode is resumed.  Time is considered to be "running" upon receipt of
  374. the first quarter frame message after a Full Message.
  375.  
  376.  
  377.      Do not send quarter frame messages continuously in a shuttle mode at high
  378. speed, since this unnecessarily clogs the MIDI data lines.  If you must
  379. periodically update a device's time code during a long shuttle, then send a
  380. Full Message every so often.
  381.  
  382.  
  383.      The quarter frame message F1 0X (Frame Count LS nibble) must be sent on a
  384. frame boundary.  The frame number indicated by the frame count is the number
  385. of the frame which starts on that boundary.  This follows the same convention
  386. as normal SMPTE longitudinal time code, where bit 00 of the 80-bit message
  387. arrives at the precise time that the frame it represents is actually starting.
  388. The SMPTE time will be incremented by 2 frames for each 8-message sequence,
  389. since an 8-message sequence will take 2 frames to send.
  390.  
  391.  
  392.  
  393.      Another way to look at it is:  When the last quarter frame message (F1
  394. 7X) arrives and the time can be fully assembled, the information is now
  395. actually 2 frames old.  A receiver of this time must keep an internal offset
  396. of +2 frames for displaying. This may seem unusual, but it is the way normal
  397. SMPTE is received and also makes backing up (running time code backwards) less
  398. confusing - when receiving the 8 quarter frame messages backwards, the F1 0X
  399. message still falls on the boundary of the frame it represents.
  400.  
  401.  
  402.  
  403.  
  404.  
  405.      Each quarter frame message number (0->7) indicates which of the 8 quarter
  406. frames of the 2-frame sequence we are on.  For example, message 0 (F1 0X)
  407. indicates quarter frame 0 of frame #1 in the sequence, and message 4 (F1 4X)
  408. indicates quarter frame 1 of frame #2 in the sequence.  If a reader receives
  409. these message numbers in descending sequence, then it knows that time code is
  410. being sent in the reverse direction.  Also, a reader can come on line at any
  411. time and know exactly where it is in relation to the 2-frame sequence, down to
  412. a quarter frame accuracy.
  413.  
  414.  
  415.  
  416.      It is the responsibility of the time code reader to insure that MTC is
  417. being properly interpreted.  This requires waiting a sufficient amount of time
  418. in order to achieve time code lock, and maintaining that lock until
  419. synchronization is dropped. Although each passing quarter frame message could
  420. be interpreted as a relative quarter frame count, the time code reader should
  421. always verify the actual complete time code after every 8-message sequence (2
  422. frames) in order to guarantee a proper lock.
  423.  
  424.  
  425.  
  426.      For example, let's assume the time is 01:37:52:16 (30 frames per second,
  427. non-drop).  Since the time is sent from least to most significant digit, the
  428. first two Quarter Frame messages will contain the data 16 (frames), the second
  429. two will contain the data 52 (seconds), the third two will represent 37
  430. (minutes), and the final two encode the 1 (hours and SMPTE Type).  The Quarter
  431. Frame Messages description defines how the binary data for each time field is
  432. spread across two nibbles. This scheme (as opposed to simple BCD) leaves some
  433. extra bits for encoding the SMPTE type (and for future use).
  434.  
  435.  
  436.  
  437.      Now, let's convert our example time of 01:37:52:16 into Quarter Frame
  438. format, putting in the correct hexadecimal conversions:
  439.  
  440.  
  441.  
  442.      F1 00
  443.  
  444.      F1 11     10H = 16 decimal
  445.  
  446.  
  447.  
  448.      F1 24
  449.  
  450.      F1 33     34H = 52 decimal
  451.  
  452.  
  453.  
  454.      F1 45
  455.  
  456.      F1 52     25H = 37 decimal
  457.  
  458.  
  459.  
  460.      F1 61
  461.  
  462.      F1 76     01H = 01 decimal (SMPTE Type is 30 frames/non-drop)
  463.  
  464.  
  465.  
  466.      (note:  the value transmitted is "6" because the SMPTE Type (11 binary) is
  467. encoded in bits 5 and 6)
  468.  
  469.  
  470.  
  471.      For SMPTE Types of 24, 30 drop frame, and 30 non-drop frame, the frame
  472. number will always be even.  For SMPTE Type of 25, the frame number may be
  473. even or odd, depending on which frame number the 8-message sequence had
  474. started.  In this case, you can see where the MIDI Time Code frame number
  475. would alternate between even and odd every second.
  476.  
  477.  
  478.  
  479.      MIDI Time Code will take a very small percentage of the MIDI bandwidth.
  480. The fastest SMPTE time rate is 30 frames per second.  The specification is to
  481. send 4 messages per frame - in other words, a 2-byte message (640
  482. microseconds) every 8.333 milliseconds.  This takes 7.68 % of the MIDI
  483. bandwidth - a reasonably small amount.  Also, in the typical MIDI Time Code
  484. systems we have imagined, it would be rare that normal MIDI and MIDI Time Code
  485. would share the same MIDI bus at the same time.
  486.  
  487.  
  488. Full Message
  489.  
  490.  
  491.  
  492.      Quarter Frame messages handle the basic running work of the system. But
  493. they are not suitable for use when equipment needs to be fast-forwarded or
  494. rewound, located or cued to a specific time, as sending them continuously at
  495. accelerated speeds would unnecessarily clog up or outrun the MIDI data lines.
  496. For these cases, Full Messages are used, which encode the complete time into a
  497. single message. After sending a Full Message, the time code generator can
  498. pause for any mechanical devices to shuttle (or "autolocate") to that point,
  499. and then resume running by sending quarter frame messages.
  500.  
  501.  
  502.  
  503. Full Message - (10 bytes)
  504.  
  505.  
  506.  
  507.      F0 7F <chan> 01 <sub-ID 2> hr mn sc fr F7
  508.  
  509.  
  510.  
  511.           F0 7F = Real Time Universal System Exclusive Header
  512.  
  513.           <chan> = 7F (message intended for entire system)
  514.  
  515.           01 = <sub-ID 1>, 'MIDI Time Code'
  516.  
  517.           <sub-ID 2> = 01, Full Time Code Message
  518.  
  519.           hr = hours and type: 0 yy zzzzz
  520.  
  521.                yy = type:
  522.  
  523.                     00 = 24 Frames/Second
  524.  
  525.                     01 = 25 Frames/Second
  526.  
  527.                     10 = 30 Frames/Second (drop frame)
  528.  
  529.                     11 = 30 Frames/Second (non-drop frame)
  530.  
  531.                zzzzz = Hours (00->23)
  532.  
  533.           mn = Minutes (00->59)
  534.  
  535.           sc = Seconds (00->59)
  536.  
  537.           fr = Frames (00->29)
  538.  
  539.           F7 = EOX
  540.  
  541.  
  542.  
  543.  
  544.  
  545.       Time is considered to be "running" upon receipt of the first Quarter
  546. Frame message after a Full Message.
  547.  
  548.  
  549. User Bits
  550.  
  551.  
  552.  
  553.      "User Bits" are 32 bits provided by SMPTE for special functions which
  554. vary with the application, and which can be programmed only from equipment
  555. especially designed for this purpose. Up to four characters or eight digits
  556. can be written. Examples of use are adding a date code or reel number to the
  557. tape.  The User Bits tend not to change throughout a run of time code.
  558.  
  559.  
  560.  
  561. User Bits Message - (15 bytes)
  562.  
  563.  
  564.  
  565.      F0 7F <chan> 01 <sub-ID 2> u1 u2 u3 u4 u5 u6 u7 u8 u9 F7
  566.  
  567.  
  568.  
  569.           F0 7F = Real Time Universal System Exclusive Header
  570.  
  571.           <chan> = 7F (message intended for entire system)
  572.  
  573.           01 = <sub-ID 1>, MIDI TIme Code
  574.  
  575.           <sub-id 2> = 02, User Bits Message
  576.  
  577.           u1 = 0000aaaa
  578.  
  579.           u2 = 0000bbbb
  580.  
  581.           u3 = 0000cccc
  582.  
  583.           u4 = 0000dddd
  584.  
  585.           u5 = 0000eeee
  586.  
  587.           u6 = 0000ffff
  588.  
  589.           u7 = 0000gggg
  590.  
  591.           u8 = 0000hhhh
  592.  
  593.           u9 = 000000ii
  594.  
  595.           F7 = EOX
  596.  
  597.  
  598.  
  599.      These nibble fields decode in an 8-bit format:  aaaabbbb ccccdddd
  600. eeeeffff gggghhhh ii.  It forms 4  8-bit characters,  and a 2 bit Format Code.
  601. u1 through u8 correspond to SMPTE Binary Groups 1 through 8.  u9 are the two
  602. Binary Group Flag Bits, as defined by SMPTE.
  603.  
  604.  
  605.  
  606.      This message can be sent whenever the User Bits values must be
  607. transferred to any devices down the line.  Note that the User Bits Message may
  608. be sent by the MIDI Time Code Converter at any time.  It is not sensitive to
  609. any mode.
  610.  
  611.  
  612.  
  613.  
  614.  
  615. MIDI Cueing
  616.  
  617.  
  618.  
  619.      MIDI Cueing uses Set-Up Messages to address individual units in a system.
  620. (A "unit" can be be a multitrack tape deck, a VTR, a special effects
  621. generator, MIDI sequencer, etc.)
  622.  
  623.  
  624.  
  625.      Of 128 possible event types, 19 are currently defined.
  626.  
  627.  
  628.  
  629.  
  630.  
  631. Set-Up Messages (13 bytes plus any additional information):
  632.  
  633.  
  634.  
  635.      F0 7E <chan> 04 <sub-ID 2> hr mn sc fr ff sl sm <add. info> F7
  636.  
  637.  
  638.  
  639.           F0 7E = Non-Real Time Universal System Exclusive Header
  640.  
  641.           <chan> = Channel number
  642.           04 = <sub-ID 1>, MIDI Time Code
  643.  
  644.           <sub-ID 2> = Set-Up Type
  645.                00 = Special
  646.                01 = Punch In points
  647.                02 = Punch Out points
  648.                03 = Delete Punch In point
  649.                04 = Delete Punch Out point
  650.                05 = Event Start points
  651.                06 = Event Stop points
  652.                07 = Event Start points with additional info.
  653.                08 = Event Stop points with additional info.
  654.                09 = Delete Event Start point
  655.                0A = Delete Event Stop point
  656.                0B = Cue points
  657.                0C = Cue points with additional info
  658.                0D = Delete Cue point
  659.                0E = Event Name in additional info
  660.  
  661.           hr = hours and type: 0 yy zzzzz
  662.  
  663.                yy = type:
  664.                     00 = 24 Frames/Second
  665.                     01 = 25 Frames/Second
  666.                     10 = 30 Frames/Second drop frame
  667.                     11 = 30 Frames/Second non-drop frame
  668.                zzzzz = Hours (00-23)
  669.  
  670.           mn = Minutes (00-59)
  671.  
  672.           sc = Seconds (00-59)
  673.  
  674.           fr = Frames (00-29)
  675.  
  676.           ff = Fractional Frames (00-99)
  677.  
  678.           sl, sm = Event Number (LSB first)
  679.  
  680.           <add. info.>
  681.  
  682.           F7 = EOX
  683.  
  684.  
  685. Description of Set-Up Types:
  686.  
  687.  
  688.  
  689.  
  690.  
  691.      00          Special refers to the set-up information that affects a unit
  692.                  globally (as opposed to individual tracks, sounds, programs,
  693.                  sequences, etc.). In this case, the Special Type takes the
  694.                  place of the Event Number. Five are defined.  Note that types
  695.                  01 00 through 04 00 ignore the event time field.
  696.  
  697.  
  698.  
  699.           00 00     Time Code Offset refers to a relative Time Code offset for
  700. each unit. For example, a piece of video and a piece of music that are
  701. supposed to go together may be created at different times, and more than
  702. likely have different absolute time code positions - therefore, one must be
  703. offset from the other so that they will match up. Just like there is one
  704. master time code for an entire system, each unit only
  705. needs one offset value per unit.
  706.  
  707.  
  708.  
  709.           01 00     Enable Event List means for a unit to enable execution of
  710. events in its list if the appropriate MTC or SMPTE time occurs.
  711.  
  712.  
  713.  
  714.           02 00     Disable Event List means for a unit to disable execution
  715. of its event list but not to erase it. This facilitates an MTC Event Manager
  716. in muting particular devices in order to concentrate on others in a complex
  717. system where many events occur simultaneously.
  718.  
  719.  
  720.  
  721.           03 00     Clear Event List means for a unit to erase its entire
  722. event list.
  723.  
  724.  
  725.  
  726.           04 00     System Stop refers to a time when the unit may shut down.
  727. This serves as a protection against Event Starts without matching Event Stops,
  728. tape machines running past the end of the reel, and so on.
  729.  
  730.  
  731.           05 00     Event List Request is sent by a master to an MTC
  732. peripheral. If the device ID (Channel Number) matches that of the peripheral,
  733. the peripheral responds by transmitting its entire cue list as a sequence of
  734. Set Up Messages, starting from the SMPTE time indicated in the Event List
  735. Request message.
  736.  
  737.  
  738.  
  739.      01/02     Punch In and Punch Out refer to the enabling and disabling of
  740. record mode on a unit. The Event Number refers to the track to be recorded.
  741. Multiple punch in/punch out points (and any of the other event types below)
  742. may be specified by sending multiple Set-Up messages with different times.
  743.  
  744.  
  745.  
  746.      03/04     Delete Punch In or Out deletes the matching point (time and
  747. event number) from the Cue List.
  748.  
  749.  
  750.  
  751.      05/06     Event Start and Stop refer to the running or playback of an
  752. event, and imply that a large sequence of events or a continuous event is to
  753. be started or stopped. The event number refers to which event on the targeted
  754. slave is to be played. A single event (ie. playback of a specific sample, a
  755. fader movement on an automated console, etc.) may occur several times
  756. throughout a given list of cues.  These events will be represented by the same
  757. event number, with different Start and Stop times.
  758.  
  759.  
  760.  
  761.      07/08     Event Start and Stop with Additional Information refer to an
  762. event (as above) with additional parameters transmitted in the Set Up message
  763. between the Time and EOX. The additional parameters may take the form of an
  764. effects unit's internal parameters, the volume level of a sound effect, etc.
  765. See below for a description of additional information.
  766.  
  767.  
  768.      09/0A     Delete Event Start/Stop means to delete the matching (event
  769. number and time) event (with or without additional information) from the Cue
  770. List.
  771.  
  772.  
  773.  
  774.      0B          Cue Point refers to individual event occurences, such as
  775. marking "hit" points for sound effects, reference points for editing, and so
  776. on.  Each Cue number may be assigned to a specific reaction, such as a
  777. specific one-shot sound event (as opposed to a continuous event, which is
  778. handled by Start/Stop).  A single cue may occur several times throughout a
  779. given list of cues.  These events will be represented by the same event
  780. number, with different Start and Stop times.
  781.  
  782.  
  783.  
  784.      0C          Cue Point with Additional Information is exactly like Event
  785. Start/Stop with Additional Information, except that the event represents a Cue
  786. Point rather than a Start/Stop Point.
  787.  
  788.  
  789.  
  790.      0D          Delete Cue Point means to Delete the matching (event number
  791. and time) Cue Event with or without additional information from the Cue List.
  792.  
  793.  
  794.  
  795.      0E          Event Name in Additional Information.  This merely assigns a
  796. name to a given event number.  It is for human logging purposes.  See
  797. Additional Information description.
  798.  
  799.  
  800.  
  801.  
  802.  
  803. Event Time
  804.  
  805.  
  806.  
  807.      This is the SMPTE/MIDI Time Code time at which the given event is
  808. supposed to occur.  Actual time is in 1/100th frame resoultion, for those
  809. units capable of handling bits or some other form of sub-frame resolution, and
  810. should otherwise be self-explanatory.
  811.  
  812.  
  813.  
  814. Event Number
  815.  
  816.  
  817.  
  818.      This is a fourteen-bit value, enabling 16,384 of each of the above types
  819. to be individually addressed. "sl" is the 7 LS bits, and "sm" is the 7 MS
  820. bits.
  821.  
  822.  
  823.  
  824. Additional Information description
  825.  
  826.  
  827.  
  828.      Additional information consists of a nibblized MIDI data stream, LS
  829. nibble first.  The exception is Set-Up Type OE, where the additional
  830. information is nibblized ASCII, LS nibble first.  An ASCII newline is
  831. accomplished by sending CR and LF in the ASCII. CR alone functions solely as a
  832. carriage return, and LF alone functions solely as a Line-Feed.
  833.  
  834.  
  835.  
  836.      For example, a MIDI Note On message such as 91 46 7F would be nibblized
  837. and sent as 01 09  06 04 0F 07.  In this way, any device can decode any
  838. message regardless of who it was intended for.  Device-specific messages
  839. should be sent as nibblized MIDI System Exclusive messages.
  840.  
  841.  
  842. Potential Problems
  843.  
  844.  
  845.  
  846.      There is a possible problem with MIDI merger boxes improperly handling
  847. the F1 message, since they do not currently know how many bytes  are
  848. following. However, in typical MIDI Time Code systems, we do not anticipate
  849. applications where the MIDI Time Code must be merged with other MIDI signals
  850. occuring at the same time.
  851.  
  852.  
  853.  
  854.      Please note that there is plenty of room for additional set-up types,
  855. etc., to cover unanticipated situations and configurations.
  856.  
  857.  
  858.  
  859.      It is recommended that each MTC peripheral power up with its MIDI
  860. Manufacturer's System Exclusive ID number as its default channel/device ID.
  861. Obviously, it would be preferable to allow the user to change this number from
  862. the device's front panel, so that several peripherals from the same
  863. manufacturer may have unique IDs within the same MTC system.
  864.  
  865.  
  866.  
  867.  
  868.  
  869. Signal Path Summary
  870.  
  871.  
  872.  
  873.      Data sent between the Master Time Code Source (which may be, for example,
  874. a Multitrack Tape Deck with a SMPTE Synchronizer) and the MIDI Time Code
  875. Converter is always SMPTE Time Code.
  876.  
  877.  
  878.  
  879.      Data sent from the MIDI Time Code Converter to the Master Control/Cue
  880. Sheet (note that this may be a MTC-equipped tape deck or mixing console as
  881. well as a cue-sheet) is always MIDI Time Code.  The specific MIDI Time Code
  882. messages which are used depend on the current operating mode, as explained
  883. below:
  884.  
  885.  
  886.       Play Mode:  The Master Time Code Source (tape deck) is in normal PLAY
  887.                   MODE at normal or vari-speed rates.  The MIDI Time Code
  888.                   Converter is transmitting Quarter Frame ("F1") messages to
  889.                   the Master Control/Cue Sheet.  The frame messages are in
  890.                   ASCENDING order, starting with "F1 0X" and ending with "F1
  891.                   7X". If the tape machine is capable of play mode in REVERSE,
  892.                   then the frame messages will be transmitted in REVERSE
  893.                   sequence, starting with "F1 7X" and ending with "F1 0X".
  894.  
  895.  
  896.  
  897.       Cue Mode:   The Master Time Code Source is being "rocked", or "cued" by
  898.                   hand.  The  tape is still contacting the playback head so
  899.                   that the listener can cue, or preview the    contents of the
  900.                   tape slowly. The MIDI Time Code Converter is transmitting
  901.                   FRAME ("F1") messages to the Master Control/Cue Sheet.  If
  902.                   the tape is being played in the FORWARD direction, the frame
  903.                   messages are sent in ASCENDING order, starting with "F1 0X"
  904.                   and ending with "F1 7X". If the tape machine is played in
  905.                   the REVERSE direction, then the frame messages will be
  906.                   transmitted in REVERSE sequence, starting with "F1 7X" and
  907.                   ending with "F1 0X".
  908.  
  909.  
  910.  
  911.                   Because the tape is being moved by hand in Cue Mode, the
  912.                   tape direction can change quickly and often.  The order of
  913.                   the Frame Message sequence must change along with the tape
  914.                   direction.
  915.  
  916.  
  917.  
  918.        Fast-Forward/Rewind Mode:  In this mode, the tape is in a
  919.                   high-speed wind or  rewind, and is not touching the playback
  920.                   head.  No "cueing" of the taped material is going on.  Since
  921.                   this is a "search" mode, synchronization of the Master
  922.                   Control/Cue Sheet is not as important as in the Play or Cue
  923.                   Mode.  Thus, in this mode, the MIDI Time Code Converter only
  924.                   needs to send a "Full Message" every so often to the Cue
  925.                   Sheet.  This acts as a rough indicator of the Master's
  926.                   position.  The SMPTE time indicated by the "Full Message"
  927.                   actually takes effect upon the reception of the next "F1"
  928.                   quarter frame message (when "Play Mode" has resumed).
  929.  
  930.  
  931.  
  932.       Shuttle Mode:  This is just another expression for "Fast-Forward/Rewind
  933.                   Mode".
  934.  
  935.  
  936.  
  937.  
  938.  
  939.  
  940. References and Credits
  941.  
  942.  
  943.  
  944.      SMPTE 12M (ANSI V98.12M-1981).
  945.  
  946.  
  947.  
  948.      MIDI Time Code specification created by Chris Meyer and Evan Brooks of
  949. Digidesign. Thanks to Stanley Jungleib of Sequential for additional text.
  950. Also many thanks to all of the MMA and JMSC members for their suggestions and
  951. contributions to the spec.
  952.  
  953.  
  954.